public class protice08 {
    public static void main(String[] args) {
        /**
         * 有数列：9，99，999，9999...，编程计算前10项值的和
         */
        double num = 0;
        double sum = 0;
        for (int i=0;i<=10;i++){
             num = num * 10 + 9;
             sum +=num;
        }
        System.out.println(sum);
    }
}
